import 'virtual:uno.css'

import '@/assets/style/index.less'
import ArcoVue from '@arco-design/web-vue'
// import '@arco-design/web-vue/dist/arco.less'
// import '@arco-themes/vue-cloudcompute/index.less'
import '@arco-themes/vue-hyper-cdn-shouquan01/index.less'
import HljsVuePlugin from '@highlightjs/vue-plugin'
import 'highlight.js/styles/atom-one-dark.css'
import 'highlight.js/lib/common'

import { createPinia } from 'pinia'
import piniaPluginPersistedState from 'pinia-plugin-persistedstate'
import { createApp } from 'vue'
import { SingleApis } from './apis/http'
import App from './App.vue'
import './assets/style/global.less'
import router from './router'
import { useAppStore } from './stores/app'
const baseURL = import.meta.env.VITE_BASE_URL
console.log('baseURL: ', baseURL)
SingleApis.init(
  {
    baseURL: baseURL,
    mode: 'admin'
  },
  () => {
    const appStore = useAppStore()
    appStore.clearLoginInfoAction()
  }
)
const app = createApp(App)
const store = createPinia()
store.use(piniaPluginPersistedState)
app.use(store)
app.use(router)
app.use(ArcoVue)
app.use(HljsVuePlugin)
app.mount('#app')
